package com.lg.houtai.manager;

import java.util.HashMap;
import java.util.Set;

import com.lg.wxq.ui.BaseActivity;

public class ActivityManager {
	private HashMap<Integer, BaseActivity> allActivity;
	
	private static ActivityManager instance=new ActivityManager();
	
	private ActivityManager(){
		allActivity=new HashMap<Integer, BaseActivity>();
	}
	
	public static ActivityManager getInstance(){
		return instance;
	}
	
	public int getSize(){
		return allActivity.size();
	}
	
	public BaseActivity getActivity(int key){
		return allActivity.get(key);
	}
	
	public void removeActivity(BaseActivity activity){
		allActivity.remove(activity.getActID());
	}

	public void addActivity(BaseActivity activity) {
		allActivity.put(activity.getActID(), activity);
	}
	
	public Set<Integer> getActivityKeySet(){
		return allActivity.keySet();
	}
}
